//
//  Const.swift
//  CMDB
//
//  Created by 曹桂祥 on 17/4/6.
//  Copyright © 2017年 CMDB. All rights reserved.
//

import UIKit
// MARK: 屏幕相关
public let CMDB_Screen: UIScreen       = UIScreen.mainScreen()

public let CMDB_Screen_Width: CGFloat  = CGRectGetWidth(UIScreen.mainScreen().bounds)

public let CMDB_Screen_Height: CGFloat = CGRectGetHeight(UIScreen.mainScreen().bounds)

public let CMDB_Screen_Bounds: CGRect  = UIScreen.mainScreen().bounds

public let Screen: UIScreen            = UIScreen.mainScreen()

public let KStatusBarHeight: CGFloat   = 20

public let KNavBarHeight: CGFloat      = 44

public let KTabBarHeight : CGFloat     = 49

public let KleftMargin : CGFloat       = 15

public let MaxSize : CGSize            = CGSize(width: 999, height: 999)
// MARK: UI全局参数
public let CMDB_Rate: CGFloat          = CMDB_Screen_Height / 1334.0

public let titelBottomMargin : CGFloat = 5

public let separateLineAlpha: Float    = 0.12

public let labelBlackColor : Int       = 0x000000

public let labelWhiteColor : Int       = 0xffffff

public let labelFirBlackAlpha : Float  = 0.87

public let labelThBlacklAlpha : Float  = 0.54

public let labelSecBlacklAlpha : Float = 0.38

//MARK: - 颜色相关
//滚动titleView的背景色
public let pageTitBackColor : UIColor  = UIColor.Hex6(0xfdfdfd)

//分割头部的背景色
public let singleViewColor : UIColor   = UIColor.Hex6(0xf2f2f2)

public let word87Color : UIColor       = UIColor.Hex6(labelBlackColor, alpha: labelFirBlackAlpha)

public let word54Color   : UIColor     = UIColor.Hex6(labelBlackColor, alpha:labelThBlacklAlpha)

public let word38Color : UIColor       = UIColor.Hex6(labelBlackColor, alpha: labelSecBlacklAlpha)

public let word12Color : UIColor       = UIColor.Hex6(labelBlackColor, alpha: separateLineAlpha)

//白色字0.87透明度
public let whiteColor87 : UIColor      = UIColor.Hex6(labelWhiteColor, alpha:labelFirBlackAlpha)

//橘黄色
public let orangeColor : UIColor       = UIColor.Hex(0xff6d00)


typealias CMDBDataBlock = (AnyObject? ,AnyObject? ,AnyObject?) -> ()

public let Max_selectedImages : Int    = 9

// MARK: 设备信息
/***********************************
 **     设备名
 ***********************************/
public let DeviceName: String = UIDevice.currentDevice().name
/***********************************
 **   操作系统
 ***********************************/
public let DeviceOS: String = UIDevice.currentDevice().systemName
/***********************************
 **  设备id
 ***********************************/
public let DeviceVersion: String = UIDevice.currentDevice().systemVersion
/***********************************
 **  设备id
 ***********************************/
public let DeviceId: String = UIDevice.currentDevice().identifierForVendor!.UUIDString
/***********************************
 **  设备机型
 ***********************************/
public let DeviceModel: String = String.correspondVersion()!
/***********************************
 **  像素
 ***********************************/
public let DeviceResolution: String = NSStringFromCGSize(CGSizeMake(CMDB_Screen_Width * Screen.scale, CMDB_Screen_Height * Screen.scale))

//MARK:- 通知
public let ShowDismissFrameNote = "ShowDismissFrameNote"

public let ShowSliederDrawerNote = "ShowSliederDrawerNote"

public let AllowSliderDrawerNote = "AllowSliderDrawerNote"
